package com.mybatistest.entity;

import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.validation.constraints.NotBlank;
import java.io.Serializable;

/**
 * <p>
 * 
 * </p>
 *
 * @author wangrunfu
 * @since 2024-08-30
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
@TableName("t_mybatis")
@ApiModel(value="Mybatis对象", description="接受数据")
public class Mybatis implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "姓名", required = true, example = "root")
    @NotBlank(message = "姓名不能为空")
    private String name;

    @ApiModelProperty(value = "身份证号", required = true, example = "123456789")
    @TableId("citizen")
    @NotBlank(message = "身份证号不能为空")
    private String citizen;
}
